<?php

namespace App\Http\Requests\Admin;

use Illuminate\Foundation\Http\FormRequest;

class Qh_LitQuestionRequest extends FormRequest
{
    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules(): array
    {
        return [
            'parentId' => 'bail|required|integer|exists:qh_questions,id',
            'questionTypeId' => 'bail|required|integer',
            'title' => 'bail|required|string',
            'options' => 'bail|nullable|string',
            'optionCount' => 'bail|nullable|integer',
            'answer' => 'bail|nullable|string',
            'analysis' => 'bail|nullable|string',
            'area' => 'bail|nullable|string',
            'province' => 'bail|nullable|string',
            'questionFrom' => 'bail|nullable|string',
            'difficulty' => 'bail|nullable|numeric',
            'difficultyValue' => 'bail|nullable|numeric',
            'rightCount' => 'bail|nullable|integer',
            'wrongCount' => 'bail|nullable|integer',
            'sort' => 'bail|nullable|integer',
        ];
    }
}
